Separate Abstract Interpretation for Control-Flow Analysis
نویسندگان
چکیده
Effect systems and abstract interpretation are two methods to perform static analysis of programs. We present a new technique that builds upon the type and effect information of module signatures to extend abstract interpretation in the context of separate compilation. We use control-flow analysis as an application of this idea to support our claim. Control-flow analysis strives to determine at compile time which functions, in a given call environment, may be called by a particular application expression. This static control-flow analysis can be expressed using either a type and effect system or abstract interpretation. The type and effect approach supports separate compilation but, being structural, collapses all call environments together, thus limiting the precision of control-flow information. By contrast, the abstract interpretation approach fails to support separate compilation but, because of its more operational nature, can distinguish between call environments, thus performing a more precise analysis. We present a new static control-flow analysis that combines both techniques in a single framework. This separate abstract interpretation is as effective as the abstract interpretation approach on closed expressions, but is also able to tackle expressions with free variables, using their types to approximate their abstract values. We prove that this separate abstract interpretation analysis is a conservative extension of abstract interpretation.
منابع مشابه
Control-flow analysis of function call and returns by abstract interpretation
We derive a control-flow analysis that approximates the interprocedural control-flow of both function calls and returns in the presence of first-class functions and tail-call optimization. In addition to an abstract environment, our analysis computes for each expression an abstract control stack, effectively approximating where function calls return across optimized tail calls. The analysis is ...
متن کاملInterprocedural Control Flow Analysis
Control Flow Analysis is a widely used approach for analysing functional and object oriented programs. Once the applications become more demanding also the analysis needs to be more precise in its ability to deal with mutable state (or side-effects) and to perform polyvariant (or context-sensitive) analysis. Several insights in Data Flow Analysis and Abstract Interpretation show how to do so fo...
متن کاملA Calculational Approach to Control-Flow Analysis by Abstract Interpretation
We present a derivation of a control-flow analysis by abstract interpretation. Our starting point is a transition system semantics defined as an abstract machine for a small functional language in continuation-passing style. We obtain a Galois connection for abstracting the machine states by composing Galois connections, most notable an independent-attribute Galois connection on machine states ...
متن کاملAutomated techniques for higher-order program verification
interpretation techniques are used to derive a control-flow analysis for a simple higher-order functional language. The analysis approximates the interprocedural control-flow of both function calls and returns in the presence of first-class functions and tail-call optimization. The analysis is systematically derived by abstract interpretation of the stack-based CaEK abstract machine of Flanagan...
متن کاملCompositional Separate Modular Static Analysis of Programs by Abstract Interpretation
The purpose of this paper is to present four ba sic methods for compositional separate modular static analy sis of programs by abstract interpretation: • Simplification-based separate analysis; • Worst-case separate analysis; • Separate analysis with (user-provided) interfaces; • Symbolic relational separate analysis; as well as a fifth category which is essentially obtained by composition of...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 1994